<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
    var a=1;
    var b=2;
    //conlose.log(typeof a,typeof b);
    var c="hello"
    var d='word'
    console.log(typeof c,typeof d);//string string
    var e=true;
    var f=false;
    console.log(typeof e,typeof f);//boolean boolean
    var g;
    console.log(typeof g);// undefined

    let obj={};
    console.log(typeof obj);//object
    obj.name="张三";
    obj.age=18;
    console.log(obj);
    console.log(obj.name,obj.age);

    let obj2={
        name:"张三",
        age:18
    };
    console.log(obj2);
    obj2.likes="football";
    console.log(obj2);
    console.log(obj2.name,obj2.age,obj2.likes);
    console.log(obj2.play);

    let arr=[1,2,33,'3',true];
    console.log(arr);
    console.log(arr[0],arr[1],arr[2],arr[3]);
    console.log(arr[100]);

    console.log(Number(true));
    console.log(Number(false));
    console.log(Number('123'));
    console.log(Number('3.14'));
    console.log(Number('哈哈哈哈'));

    console.log(Boolean(0));
    console.log(Boolean(null));
    console.log(Boolean(undefined));
    console.log(Boolean(NaN));
    console.log(Boolean(''));
    console.log(Boolean('hhhh'));
    console.log(Boolean(' '));
    console.log(Boolean(1));
</script>
</body>
</html>